<template>
  <div class="itemBox">
    <div class="rankItem" v-for="(item,index) in arr" :key="index">
      <span>{{index+1}}</span>
      <p>{{item}}</p>
    </div>
  </div>
</template>

<script>
import { defineComponent } from 'vue'
export default defineComponent({
  props: {
    arr: {
      typeof: Array,
      default: []
    }
  }
})
</script>

<style lang='less' scoped>
.itemBox {
  margin-top: 43px;
  .rankItem {
    width: 367px;
    display: flex;
    align-items: center;
    padding: 11px 15px;
    width: 367px;
    box-sizing: border-box;
    span {
      display: flex;
      justify-content: center;
      align-items: center;
      margin-right: 15px;
      width: 16px;
      height: 16px;
      background: #3072f6;
      font-family: 'HarmonyOS Sans SC';
      font-style: normal;
      font-weight: 400;
      font-size: 12px;
      line-height: 14px;
      color: #ffffff;
    }
    p {
      font-family: 'HarmonyOS Sans SC';
      font-style: normal;
      font-weight: 400;
      font-size: 12px;
      line-height: 14px;
      color: #666666;
    }
  }
  .rankItem:nth-child(2n) {
    background-color: #f5f5f5;
  }
}
</style>
